package com.example.consumerdemo1.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.example.serviceapi.service.DubboTestService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/*********************************************************
 * @Author ONE_LLX
 * @Description //TODO 
 * @Date 19:32 2019/11/23
 * @Class DubboTestController
 * @Version v1.0
 *********************************************************/
@RestController
public class DubboTestController {

    @Reference(version = "1.0",timeout = 300)
    private DubboTestService dubboTestService;

    @GetMapping("/hello")
    public String test(){
        String test = dubboTestService.test();
        System.out.println(test);
        return test;
    }
}
